package com.xjtu.se.homework.client.result.service.impl;

import com.xjtu.se.homework.client.result.dao.ClientResultDao;
import com.xjtu.se.homework.client.result.service.ClientResultService;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import javax.annotation.Resource;

@Service
@Transactional
public class ClientResultServiceImpl implements ClientResultService {

    @Resource
    private ClientResultDao clientResultDao;

    @Override
    public void updateMistakeBySearchID(String  search_id, int is_marked) {
        clientResultDao.updateMistake(search_id, is_marked);
    }

    @Override
    public int getMistakeBySearchID(String search_id) {
        return clientResultDao.getMistake(search_id);
    }

}
